package com.nowcoder.code.lcof;

public class JZ10 {

    public static void main(String[] args) {
        System.out.println(new JZ10().Fibonacci(1));
    }

    public int Fibonacci(int n) {
        int i = 2;
        int s1 = 1;
        int s2 = 1;
        int tmp;
        for (; i < n; i++) {
            tmp = s2;
            s2 = s1 + s2;
            s1 = tmp;
        }
        return s2;
    }


}
